/**
 * Created by LC on 2019/11/21
 */
package com.hw.paltfrom.controller.mainscreen;

import com.hw.paltfrom.rescode.HWSystemCode;
import com.hw.paltfrom.service.mainscreen.StationCountService;
import com.hw.paltfrom.utils.ResponeResultUtil;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * 某超限站的执法监管,指挥调度的统计
 */
@RestController
@RequestMapping("stationCount")
public class StationCountController {
    @Autowired
    private StationCountService stationCountService;

    @RequestMapping("query")
    public Map<String,Object> queryCount(String overrunCode){
        if (StringUtils.isBlank(overrunCode)) {
            return ResponeResultUtil.failNotice(HWSystemCode.FAIL,"不传参数我给你查啥?");
        }
        return stationCountService.queryCount(overrunCode);
    }

}
